package com.neisha.job;

import org.quartz.Job;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.neisha.kit.Content;
import com.neisha.kit.JobKit;

/**
 * 一天执行一次的job
 * @author cyy
 */
public class OneDayJob implements Job{
	
	Logger logger = LoggerFactory.getLogger(OneDayJob.class);

	String api = "/api/times/oneday"; // 一天执行一次的任务
	
	@Override
	public void execute(JobExecutionContext context) throws JobExecutionException {
		String jobKey = context.getJobDetail().getKey().getName();
		String res = JobKit.executeUrl(Content.HOST+api,jobKey);
		logger.info("一天执行一次任务执行结果："+res);
	}

}
